from pymysql import connect

connection = connect(host='127.0.0.1', port=3306, user='root', password='root', db='bjsxt', charset='utf8')
print(connection)

cursor = connection.cursor()
sql = 'select * from employees'

cursor.execute(sql)
emp = cursor.fetchall()
# print(emp)
for e in emp:
    print(e,end='\n')